﻿package  
{
	
	import flash.display.MovieClip;
	import flash.events.MouseEvent;
	
	
	public class NpcTalkUI extends MovieClip 
	{
		public var px:int = 128;
		public var py:int = 144;
		
		
		public function NpcTalkUI() 
		{
			// constructor code
			stop();
			
			setButtonMode( 0 );
		}
		
		
		public function setButtonMode( m:int ):void
		{
			switch( m )
			{
				case 0:
				{
					closeButton.visible = false;
					nextButton.visible = false;
					okButton.visible = false;
					cancelButton.visible = false;
				}
				break;
				case 1:
				{
					closeButton.visible = true;
					nextButton.visible = false;
					okButton.visible = false;
					cancelButton.visible = false;
				}
				break;
				case 2:
				{
					closeButton.visible = false;
					nextButton.visible = false;
					okButton.visible = true;
					cancelButton.visible = true;
				}
				break;
				case 3:
				{
					closeButton.visible = false;
					nextButton.visible = true;
					okButton.visible = false;
					cancelButton.visible = false;
				}
				break;
				
			
			}
		}
		
		public function setText( t:String , s:String ):void
		{
			titleText.htmlText = t;
			wordText.htmlText = s;
		}
		
		
	}
	
}
